<template>
<div id="tree">
    <treedetail :title="list.name" :list="list.children" :num="0"/>
</div>
</template>
<script>
const list = {
  name: '电子产品',
  children: [
    {
      name: '电视',
      children: [
        {
          name: 'philips',
          children: [
            { name: 'philips-A' },
            { name: 'philips-B' },
            { name: 'philips-C' }
          ]
        },
        {
          name: 'Tcl',
          children: [
            { name: 'Mac Air' },
            { name: 'Mac Pro' },
            {
              name: 'ThinlPad',
              children: [
                {
                  name: 'ThinlPad-A',
                  children: [
                    { name: 'ThinlPad-A-a' },
                    { name: 'ThinlPad-A-b' },
                    { name: 'ThinlPad-A-c' }
                  ]
                },
                { name: 'ThinlPad-B' },
                { name: 'ThinlPad-C' },
                { name: 'ThinlPad-D' }
              ]
            }
          ]
        },
        { name: '海兴' }
      ]
    },
    {
      name: '电脑',
      children: [{ name: 'acer' }, { name: '联想' }, { name: '惠普' }]
    },
    {
      name: '可穿戴的设备',
      children: [
        {
          name: '手环',
          children: [
            { name: '华为B5手环' },
            { name: '小米手环' },
            { name: 'iphone手环' }
          ]
        }
      ]
    }
  ]
}
import treedetail from '../treedemo/tree-detail'
export default {
  name: 'tree',
  components: { treedetail },
  data() {
    return { list }
  }
}
</script>
